import { options1 } from '../echarts-options/common';

export function setBarOptions() {
  return function(target, name, descriptor) {
    const originFn = descriptor.value;
    descriptor.value = async function(...rest) {
      // let that = this;
      await originFn.apply(this, rest);
      // let data = this.data;
      let option = JSON.parse(JSON.stringify(options1));
      // 这里处理数据
      this.options = option; // 最后给配置项赋值
    };
  };
}
